已知三个关系:
S(SNO,NAME,SEX,CLASS);C(CNO,CNAME,TIME);
SC(SNO,CNO,DEGREE)
若要查询统计每门课各班的平均成绩和每门课的平均成绩以及总的平均成绩,下列语句
正确的是( )

单选题 每门课

浏览:
6
选项

A.select class, cname, avg(degree) as平均分 from s, sc, c where = and c.
cno= group by , c. cname with rollup
B.select class, cname, avg(degree) as 平均分 from s, sc, c where = and c.
cno =sc. cno group by s. class, c. cname with cube
C. select class, cname, avg(degree) as 平均分 from s, sc, c where =sc.
sno and c. cno =sc. cno group by c. cname, with cube
D.select class, cname, avg(degree) as 平均分 from s, sc, c where s. sno
=sc. sno and c. cno =sc. cno group by c. cname, with rollup
答案

解析

相近题目

正在获取相关题目,请稍后...